#ifndef _LUAMISC_H
#define _LUAMISC_H

class LUALog
{
public:
	static void Notice(const char* title, const char* str)
	{
		Log->Notice(title, str);
	}

	static void Warning(const char* title, const char* str)
	{
		Log->Warning(title, str);
	}

	static void Error(const char* title, const char* str)
	{
		Log->Error(title, str);
	}

	static void Success(const char* title, const char* str)
	{
		Log->Success(title, str);
	}

	static scope RegisterLUALog();
};

class LUAColor
{
public:
	LUAColor(ui8 r, ui8 g, ui8 b);
	void SetNewColor(ui8 r, ui8 g, ui8 b);
	ui32 GetColorValue();
	void SetFixColor(ui8 index);
	ui8 r, g, b;
	enum FixColors
	{
		CLR_RED,
		CLR_BLUE,
		CLR_GREEN,
		NUM_CLRS,
	};

	static scope RegisterLUAColor();
};

class LUAMoney
{
public:
	LUAMoney(ui32 gold, ui32 silver, ui32 copper);
	ui32 _gold, _silver, _copper;
	void AddGold(ui32 val);
	void AddSilver(ui32 val);
	void AddCopper(ui32 val);
	ui32 GetCopperVal();
	bool operator==(LUAMoney& mon)
	{
		return (mon.GetCopperVal() == GetCopperVal());
	}

	bool operator==(ui32& val)
	{
		return (GetCopperVal() == val);
	}

	bool operator<=(LUAMoney& mon)
	{
		return (GetCopperVal() <= mon.GetCopperVal());
	}

	bool operator<=(ui32& val)
	{
		return (GetCopperVal() <= val);
	}

	static scope RegisterLUAMoney();
};

class LUAVector
{
public:
	LUAVector(float x, float y, float z, ui32 mapid) : _x(x), _y(y), _z(z), _map(mapid)
	{
	}
	float _x, _y, _z;
	ui32 _map;
	bool operator==(LUAVector& vec2)
	{
		return (vec2._x == _x && vec2._y == _y && vec2._z == _z && vec2._map == _map);
	}

	static scope RegisterLUAVector();
};

#endif